/*
 * LookupTable.h
 *
 *  Created on: Oct 2, 2008
 *      Author: V
 */

#ifndef LOOKUPTABLE_H_
#define LOOKUPTABLE_H_

#include "../string/String.h"
#include "AnonymousStatement.h"
#include "Argument.h"

typedef struct LookupTableTag
{
	StringList labels;
	AnonymousStatementList anonymousStatements;
	int maxSize;
	int currentSize;
	int (*add)(struct LookupTableTag*, pString, pAnonymousStatement);
	pAnonymousStatement (*getMain)(struct LookupTableTag*);
} LookupTable, *pLookupTable, **LookupTableList;


int LookupTableInit();

pLookupTable LookupTable_new();

int LookupTable_add(
		pLookupTable tableObj,
		pString label,
		pAnonymousStatement statement);

pAnonymousStatement LookupTable_lookup(pLookupTable table);

pAnonymousStatement LookupTable_getMain();

#endif /* LOOKUPTABLE_H_ */
